<!DOCTYPE html>
<html>
<head>
  <title>php源码加密</title>
  <meta charset="UTF-8">
  <style>
    body {
      font-family: Arial, sans-serif;
    }

    h1 {
      text-align: center;
    }

    textarea {
      width: 600px;
      height: 150px;
      resize: none;
      border: 10px solid #eee;
    }

    button {
      padding: 10px;
      font-size: 16px;
    }
  </style>
</head>
<body>
  <h1>php源码加密</h1>

  <textarea id="inputText" placeholder="请输入内容"></textarea>
  <br><br>
  <textarea id="outputText" readonly></textarea>
  <br><br>
  <button onclick="postData()">提交</button>

  <script>
    function postData() {
      var input = document.getElementById("inputText").value;
      var xhr = new XMLHttpRequest();
      xhr.open("POST", "jm.php", true);
      xhr.setRequestHeader("Content-Type", "application/x-www-form-urlencoded");
      xhr.onreadystatechange = function () {
        if (xhr.readyState === 4 && xhr.status === 200) {
          document.getElementById("outputText").value = xhr.responseText;
        }
      };
      xhr.send("data=" + encodeURIComponent(input));
    }
  </script>
</body>
</html>